package com.augurit.gzcgwsp.qyzz.service;

import java.util.List;
import java.util.Map;
import jxl.Sheet;
import jxl.write.WritableSheet;
import com.augurit.common.base.service.ICrudService;
import com.augurit.common.system.web.auth.form.LoginUserForm;
import com.augurit.gzcgwsp.qyzz.entity.YwRqQyzzAzWxRyZs;
import com.augurit.gzcgwsp.qyzz.entity.YwRqQyzzFinalAzWxRyZs;
import com.augurit.gzcgwsp.qyzz.entity.YwRqQyzzFinalJsRy;
import com.augurit.gzcgwsp.qyzz.entity.YwRqQyzzInfo;
import com.augurit.gzcgwsp.qyzz.entity.YwRqQyzzJsRy;
import com.augurit.gzcgwsp.qyzz.entity.YwRqRyzzEquipment;
import com.augurit.gzcgwsp.qyzz.entity.YwRqRyzzFinalEquipment;
import com.augurit.gzcgwsp.qyzz.entity.YwRqRyzzFinalOtherEvidence;
import com.augurit.gzcgwsp.qyzz.entity.YwRqRyzzOtherEvidence;
import com.augurit.gzcgwsp.qyzz.web.form.YwRqQyzzInfoForm;
import com.augurit.gzcgwsp.ywcmn.entity.YwComFinalQyxx;
import com.augurit.gzcgwsp.ywcmn.web.form.YwComQyxxForm;

public interface IYwRqQyzzInfoService extends ICrudService<YwRqQyzzInfoForm, Long> {
	public void changeYslState(Long id, Long state,String yslThyy);
	public void changeIsycbl(Long id, String state);
    public void endSave(Long id);
	public List<YwRqQyzzInfo> getByAcceptNo(String acceptNo);
	/**
	 * 通过ID号,改变窗口是否可打印受理通知书状态(1为是；0和空为否)
	 * @param id id号
	 */
	public void changeSendAcceptNotice(Long id);
	
	/**
	 * 通过ID号,改变窗口是否可打印延期办理结果通知书状态(1为是；0和空为否)
	 * @param id 
	 * @return 
	 */
	public void changeSendYqNotice(Long id);
	
	/**
	 * 根据ID获得对象实体
	 * @param id
	 * @return
	 */  
    public YwRqQyzzInfo getEntity(Long id);
    
    /**
     * 保存对象实体
     * @param ywRqQyzzInfo
     */     
    public void saveEntity(YwRqQyzzInfo ywRqQyzzInfo);
    /**
     * 导入基本信息
     * @param sheet
     * @param acceptNo
     * @param qyid
     * @param username
     * @return string
     */
	public String importQyzzInfo(Sheet sheet, String acceptNo, long qyid,
			String username,Map<String,String> params);
	
	/**
	 * excel写入基本信息
	 * @param wsTwo
	 * @param acceptNo
	 * @param qyid
	 */
	public void copyWsTwo(WritableSheet wsTwo, String acceptNo, long qyid,String type);
	/**
	 * excel写入单位名称
	 * @param wsTwo
	 * @param acceptNo
	 * @param qyid
	 */
	public void copyWsOne(WritableSheet ws, String acceptNo, long qyid);
	/**
	 * 查询设备
	 * @param valueOf
	 * @return
	 */
	public YwRqRyzzEquipment getEquipment(Long valueOf);
	/**
	 * 删除设备
	 * @param valueOf
	 */
	public void delEquipment(Long valueOf);
	/**
	 * 生成证书编号
	 * @param form
	 */
    public void createZsbh(YwRqQyzzInfoForm form);

    /**
     * 获取企业信息原始数据
     * @param qyid  企业id
     * @return
     */
    public YwComFinalQyxx getYwComFinalQyxx(Long qyid);
    /**
     * 安全技术人员情况
     * @param qyid
     * @param acceptNo
     * @return
     */
    public List<YwRqQyzzJsRy> getJsRys(Long qyid, String acceptNo);
    public List<YwRqQyzzFinalJsRy>  getFinalJsRys(Long qyid);
    /**
     * 安装维修人员
     * @param qyid
     * @param acceptNo
     * @return
     */
    public List<YwRqQyzzAzWxRyZs> getAzWxRys(Long qyid, String acceptNo);
    public List<YwRqQyzzFinalAzWxRyZs> getFinalAzWxRys(Long qyid);
    /**
     * 主要设备
     * @param qyid
     * @return
     */
    public List<YwRqRyzzFinalEquipment> getFinalEquipments(Long qyid);
    public List<YwRqRyzzEquipment> getEquipments(Long qyid,String acceptNo);
    
    /**
     * 其他材料
     * @param qyid
     * @return
     */
    public List<YwRqRyzzOtherEvidence> getOtherEvidences(Long qyid,String acceptNo);
    public List<YwRqRyzzFinalOtherEvidence> getFinalOtherEvidences(Long qyid);
    /**
     * 导入最终数据
     * @param form
     */
    public Map importFinalData(YwRqQyzzInfoForm form);
    
    /**
     * 写入企业资质数据
     * @param form
     * @param context
     * @return
     */
    public String writeZsData(YwRqQyzzInfoForm form,YwComQyxxForm qyxx, String context);
    
    /**
     * 写入企业资质副本数据
     * @param form
     * @param context
     * @return
     */
    public String writeFbData(YwRqQyzzInfoForm form,YwComQyxxForm qyxx, String context);
    
    /**
     * 查询其他信息
     * @param acceptNo
     * @return
     */
	public String[] getInfos(String acceptNo);
	
	public String wfBusYslTuih(YwRqQyzzInfoForm form,LoginUserForm loginUser) throws Exception;
	/**
	 * 
	 * @param entity
	 */
	public void updateAcceptNo(YwRqQyzzInfo entity);
}